package project.menu.mainmenu;

import project.menu.IMenu;
import project.menu.IMenuItem;
import project.work.Navigator;
import controllers.IAutoservice;


public class ResaveData implements IMenuItem {

	private String name = "Resave Data";
	private final Integer id = 4;
	private static IMenu submenu;
	private Navigator n;
	
	public ResaveData(){
		n=Navigator.getInstance();
	}

	
	public static void setSubmenu(IMenu menu){
		 submenu=menu;
	}
	
	public void action(IAutoservice aut) {
		//resave data

		aut.resaveData();
		n.drawMenu(submenu);
	}

	public String getNameItem() {
		return name;
	}
	
	public Integer getId(){
		return id;
	}
	

}
